Integrand size = 23, antiderivative size = 270 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=-\frac {3 d^3 e^{-2 i e-2 i f x}}{16 a^2 f^4}-\frac {3 d^3 e^{-4 i e-4 i f x}}{512 a^2 f^4}-\frac {3 i d^2 e^{-2 i e-2 i f x} (c+d x)}{8 a^2 f^3}-\frac {3 i d^2 e^{-4 i e-4 i f x} (c+d x)}{128 a^2 f^3}+\frac {3 d e^{-2 i e-2 i f x} (c+d x)^2}{8 a^2 f^2}+\frac {3 d e^{-4 i e-4 i f x} (c+d x)^2}{64 a^2 f^2}+\frac {i e^{-2 i e-2 i f x} (c+d x)^3}{4 a^2 f}+\frac {i e^{-4 i e-4 i f x} (c+d x)^3}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d} \]
[Out]
Time = 0.33 (sec) , antiderivative size = 270, normalized size of antiderivative = 1.00, number of steps used = 10, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.130, Rules used = {3810, 2207, 2225} \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=-\frac {3 i d^2 (c+d x) e^{-2 i e-2 i f x}}{8 a^2 f^3}-\frac {3 i d^2 (c+d x) e^{-4 i e-4 i f x}}{128 a^2 f^3}+\frac {3 d (c+d x)^2 e^{-2 i e-2 i f x}}{8 a^2 f^2}+\frac {3 d (c+d x)^2 e^{-4 i e-4 i f x}}{64 a^2 f^2}+\frac {i (c+d x)^3 e^{-2 i e-2 i f x}}{4 a^2 f}+\frac {i (c+d x)^3 e^{-4 i e-4 i f x}}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d}-\frac {3 d^3 e^{-2 i e-2 i f x}}{16 a^2 f^4}-\frac {3 d^3 e^{-4 i e-4 i f x}}{512 a^2 f^4} \]
[In]
[Out]
Rule 2207
Rule 2225
Rule 3810
Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {(c+d x)^3}{4 a^2}+\frac {e^{-2 i e-2 i f x} (c+d x)^3}{2 a^2}+\frac {e^{-4 i e-4 i f x} (c+d x)^3}{4 a^2}\right ) \, dx \\ & = \frac {(c+d x)^4}{16 a^2 d}+\frac {\int e^{-4 i e-4 i f x} (c+d x)^3 \, dx}{4 a^2}+\frac {\int e^{-2 i e-2 i f x} (c+d x)^3 \, dx}{2 a^2} \\ & = \frac {i e^{-2 i e-2 i f x} (c+d x)^3}{4 a^2 f}+\frac {i e^{-4 i e-4 i f x} (c+d x)^3}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d}-\frac {(3 i d) \int e^{-4 i e-4 i f x} (c+d x)^2 \, dx}{16 a^2 f}-\frac {(3 i d) \int e^{-2 i e-2 i f x} (c+d x)^2 \, dx}{4 a^2 f} \\ & = \frac {3 d e^{-2 i e-2 i f x} (c+d x)^2}{8 a^2 f^2}+\frac {3 d e^{-4 i e-4 i f x} (c+d x)^2}{64 a^2 f^2}+\frac {i e^{-2 i e-2 i f x} (c+d x)^3}{4 a^2 f}+\frac {i e^{-4 i e-4 i f x} (c+d x)^3}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d}-\frac {\left (3 d^2\right ) \int e^{-4 i e-4 i f x} (c+d x) \, dx}{32 a^2 f^2}-\frac {\left (3 d^2\right ) \int e^{-2 i e-2 i f x} (c+d x) \, dx}{4 a^2 f^2} \\ & = -\frac {3 i d^2 e^{-2 i e-2 i f x} (c+d x)}{8 a^2 f^3}-\frac {3 i d^2 e^{-4 i e-4 i f x} (c+d x)}{128 a^2 f^3}+\frac {3 d e^{-2 i e-2 i f x} (c+d x)^2}{8 a^2 f^2}+\frac {3 d e^{-4 i e-4 i f x} (c+d x)^2}{64 a^2 f^2}+\frac {i e^{-2 i e-2 i f x} (c+d x)^3}{4 a^2 f}+\frac {i e^{-4 i e-4 i f x} (c+d x)^3}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d}+\frac {\left (3 i d^3\right ) \int e^{-4 i e-4 i f x} \, dx}{128 a^2 f^3}+\frac {\left (3 i d^3\right ) \int e^{-2 i e-2 i f x} \, dx}{8 a^2 f^3} \\ & = -\frac {3 d^3 e^{-2 i e-2 i f x}}{16 a^2 f^4}-\frac {3 d^3 e^{-4 i e-4 i f x}}{512 a^2 f^4}-\frac {3 i d^2 e^{-2 i e-2 i f x} (c+d x)}{8 a^2 f^3}-\frac {3 i d^2 e^{-4 i e-4 i f x} (c+d x)}{128 a^2 f^3}+\frac {3 d e^{-2 i e-2 i f x} (c+d x)^2}{8 a^2 f^2}+\frac {3 d e^{-4 i e-4 i f x} (c+d x)^2}{64 a^2 f^2}+\frac {i e^{-2 i e-2 i f x} (c+d x)^3}{4 a^2 f}+\frac {i e^{-4 i e-4 i f x} (c+d x)^3}{16 a^2 f}+\frac {(c+d x)^4}{16 a^2 d} \\ \end{align*}
Time = 2.54 (sec) , antiderivative size = 473, normalized size of antiderivative = 1.75 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=\frac {\sec ^2(e+f x) (\cos (f x)+i \sin (f x))^2 \left (\left (4 i c^3 f^3+6 c^2 d f^2 (1+2 i f x)+6 c d^2 f \left (-i+2 f x+2 i f^2 x^2\right )+d^3 \left (-3-6 i f x+6 f^2 x^2+4 i f^3 x^3\right )\right ) \cos (2 f x)+\frac {1}{32} \left (32 i c^3 f^3+24 c^2 d f^2 (1+4 i f x)+12 c d^2 f \left (-i+4 f x+8 i f^2 x^2\right )+d^3 \left (-3-12 i f x+24 f^2 x^2+32 i f^3 x^3\right )\right ) \cos (4 f x) (\cos (2 e)-i \sin (2 e))+f^4 x \left (4 c^3+6 c^2 d x+4 c d^2 x^2+d^3 x^3\right ) (\cos (2 e)+i \sin (2 e))+\left (4 c^3 f^3+6 c^2 d f^2 (-i+2 f x)+6 c d^2 f \left (-1-2 i f x+2 f^2 x^2\right )+d^3 \left (3 i-6 f x-6 i f^2 x^2+4 f^3 x^3\right )\right ) \sin (2 f x)+\frac {1}{32} \left (32 c^3 f^3+24 c^2 d f^2 (-i+4 f x)+12 c d^2 f \left (-1-4 i f x+8 f^2 x^2\right )+d^3 \left (3 i-12 f x-24 i f^2 x^2+32 f^3 x^3\right )\right ) (\cos (2 e)-i \sin (2 e)) \sin (4 f x)\right )}{16 f^4 (a+i a \tan (e+f x))^2} \]
[In]
[Out]
Time = 0.75 (sec) , antiderivative size = 283, normalized size of antiderivative = 1.05
method | result | size |
risch | \(\frac {d^{3} x^{4}}{16 a^{2}}+\frac {d^{2} c \,x^{3}}{4 a^{2}}+\frac {3 d \,c^{2} x^{2}}{8 a^{2}}+\frac {c^{3} x}{4 a^{2}}+\frac {c^{4}}{16 a^{2} d}+\frac {i \left (4 d^{3} x^{3} f^{3}+12 c \,d^{2} f^{3} x^{2}-6 i d^{3} f^{2} x^{2}+12 c^{2} d \,f^{3} x -12 i c \,d^{2} f^{2} x +4 c^{3} f^{3}-6 i c^{2} d \,f^{2}-6 d^{3} f x -6 c \,d^{2} f +3 i d^{3}\right ) {\mathrm e}^{-2 i \left (f x +e \right )}}{16 a^{2} f^{4}}+\frac {i \left (32 d^{3} x^{3} f^{3}+96 c \,d^{2} f^{3} x^{2}-24 i d^{3} f^{2} x^{2}+96 c^{2} d \,f^{3} x -48 i c \,d^{2} f^{2} x +32 c^{3} f^{3}-24 i c^{2} d \,f^{2}-12 d^{3} f x -12 c \,d^{2} f +3 i d^{3}\right ) {\mathrm e}^{-4 i \left (f x +e \right )}}{512 a^{2} f^{4}}\) | \(283\) |
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 267, normalized size of antiderivative = 0.99 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=\frac {{\left (32 i \, d^{3} f^{3} x^{3} + 32 i \, c^{3} f^{3} + 24 \, c^{2} d f^{2} - 12 i \, c d^{2} f - 3 \, d^{3} - 24 \, {\left (-4 i \, c d^{2} f^{3} - d^{3} f^{2}\right )} x^{2} - 12 \, {\left (-8 i \, c^{2} d f^{3} - 4 \, c d^{2} f^{2} + i \, d^{3} f\right )} x + 32 \, {\left (d^{3} f^{4} x^{4} + 4 \, c d^{2} f^{4} x^{3} + 6 \, c^{2} d f^{4} x^{2} + 4 \, c^{3} f^{4} x\right )} e^{\left (4 i \, f x + 4 i \, e\right )} - 32 \, {\left (-4 i \, d^{3} f^{3} x^{3} - 4 i \, c^{3} f^{3} - 6 \, c^{2} d f^{2} + 6 i \, c d^{2} f + 3 \, d^{3} + 6 \, {\left (-2 i \, c d^{2} f^{3} - d^{3} f^{2}\right )} x^{2} + 6 \, {\left (-2 i \, c^{2} d f^{3} - 2 \, c d^{2} f^{2} + i \, d^{3} f\right )} x\right )} e^{\left (2 i \, f x + 2 i \, e\right )}\right )} e^{\left (-4 i \, f x - 4 i \, e\right )}}{512 \, a^{2} f^{4}} \]
[In]
[Out]
Time = 0.42 (sec) , antiderivative size = 665, normalized size of antiderivative = 2.46 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=\begin {cases} \frac {\left (\left (512 i a^{2} c^{3} f^{7} e^{2 i e} + 1536 i a^{2} c^{2} d f^{7} x e^{2 i e} + 384 a^{2} c^{2} d f^{6} e^{2 i e} + 1536 i a^{2} c d^{2} f^{7} x^{2} e^{2 i e} + 768 a^{2} c d^{2} f^{6} x e^{2 i e} - 192 i a^{2} c d^{2} f^{5} e^{2 i e} + 512 i a^{2} d^{3} f^{7} x^{3} e^{2 i e} + 384 a^{2} d^{3} f^{6} x^{2} e^{2 i e} - 192 i a^{2} d^{3} f^{5} x e^{2 i e} - 48 a^{2} d^{3} f^{4} e^{2 i e}\right ) e^{- 4 i f x} + \left (2048 i a^{2} c^{3} f^{7} e^{4 i e} + 6144 i a^{2} c^{2} d f^{7} x e^{4 i e} + 3072 a^{2} c^{2} d f^{6} e^{4 i e} + 6144 i a^{2} c d^{2} f^{7} x^{2} e^{4 i e} + 6144 a^{2} c d^{2} f^{6} x e^{4 i e} - 3072 i a^{2} c d^{2} f^{5} e^{4 i e} + 2048 i a^{2} d^{3} f^{7} x^{3} e^{4 i e} + 3072 a^{2} d^{3} f^{6} x^{2} e^{4 i e} - 3072 i a^{2} d^{3} f^{5} x e^{4 i e} - 1536 a^{2} d^{3} f^{4} e^{4 i e}\right ) e^{- 2 i f x}\right ) e^{- 6 i e}}{8192 a^{4} f^{8}} & \text {for}\: a^{4} f^{8} e^{6 i e} \neq 0 \\\frac {x^{4} \cdot \left (2 d^{3} e^{2 i e} + d^{3}\right ) e^{- 4 i e}}{16 a^{2}} + \frac {x^{3} \cdot \left (2 c d^{2} e^{2 i e} + c d^{2}\right ) e^{- 4 i e}}{4 a^{2}} + \frac {x^{2} \cdot \left (6 c^{2} d e^{2 i e} + 3 c^{2} d\right ) e^{- 4 i e}}{8 a^{2}} + \frac {x \left (2 c^{3} e^{2 i e} + c^{3}\right ) e^{- 4 i e}}{4 a^{2}} & \text {otherwise} \end {cases} + \frac {c^{3} x}{4 a^{2}} + \frac {3 c^{2} d x^{2}}{8 a^{2}} + \frac {c d^{2} x^{3}}{4 a^{2}} + \frac {d^{3} x^{4}}{16 a^{2}} \]
[In]
[Out]
Exception generated. \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=\text {Exception raised: RuntimeError} \]
[In]
[Out]
none
Time = 0.43 (sec) , antiderivative size = 368, normalized size of antiderivative = 1.36 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx=\frac {{\left (32 \, d^{3} f^{4} x^{4} e^{\left (4 i \, f x + 4 i \, e\right )} + 128 \, c d^{2} f^{4} x^{3} e^{\left (4 i \, f x + 4 i \, e\right )} + 192 \, c^{2} d f^{4} x^{2} e^{\left (4 i \, f x + 4 i \, e\right )} + 128 i \, d^{3} f^{3} x^{3} e^{\left (2 i \, f x + 2 i \, e\right )} + 32 i \, d^{3} f^{3} x^{3} + 128 \, c^{3} f^{4} x e^{\left (4 i \, f x + 4 i \, e\right )} + 384 i \, c d^{2} f^{3} x^{2} e^{\left (2 i \, f x + 2 i \, e\right )} + 96 i \, c d^{2} f^{3} x^{2} + 384 i \, c^{2} d f^{3} x e^{\left (2 i \, f x + 2 i \, e\right )} + 192 \, d^{3} f^{2} x^{2} e^{\left (2 i \, f x + 2 i \, e\right )} + 96 i \, c^{2} d f^{3} x + 24 \, d^{3} f^{2} x^{2} + 128 i \, c^{3} f^{3} e^{\left (2 i \, f x + 2 i \, e\right )} + 384 \, c d^{2} f^{2} x e^{\left (2 i \, f x + 2 i \, e\right )} + 32 i \, c^{3} f^{3} + 48 \, c d^{2} f^{2} x + 192 \, c^{2} d f^{2} e^{\left (2 i \, f x + 2 i \, e\right )} - 192 i \, d^{3} f x e^{\left (2 i \, f x + 2 i \, e\right )} + 24 \, c^{2} d f^{2} - 12 i \, d^{3} f x - 192 i \, c d^{2} f e^{\left (2 i \, f x + 2 i \, e\right )} - 12 i \, c d^{2} f - 96 \, d^{3} e^{\left (2 i \, f x + 2 i \, e\right )} - 3 \, d^{3}\right )} e^{\left (-4 i \, f x - 4 i \, e\right )}}{512 \, a^{2} f^{4}} \]
[In]
[Out]
Time = 4.30 (sec) , antiderivative size = 289, normalized size of antiderivative = 1.07 \[ \int \frac {(c+d x)^3}{(a+i a \tan (e+f x))^2} \, dx={\mathrm {e}}^{-e\,2{}\mathrm {i}-f\,x\,2{}\mathrm {i}}\,\left (\frac {\left (4\,c^3\,f^3-c^2\,d\,f^2\,6{}\mathrm {i}-6\,c\,d^2\,f+d^3\,3{}\mathrm {i}\right )\,1{}\mathrm {i}}{16\,a^2\,f^4}+\frac {d^3\,x^3\,1{}\mathrm {i}}{4\,a^2\,f}-\frac {d\,x\,\left (-2\,c^2\,f^2+c\,d\,f\,2{}\mathrm {i}+d^2\right )\,3{}\mathrm {i}}{8\,a^2\,f^3}-\frac {d^2\,x^2\,\left (-2\,c\,f+d\,1{}\mathrm {i}\right )\,3{}\mathrm {i}}{8\,a^2\,f^2}\right )+{\mathrm {e}}^{-e\,4{}\mathrm {i}-f\,x\,4{}\mathrm {i}}\,\left (\frac {\left (32\,c^3\,f^3-c^2\,d\,f^2\,24{}\mathrm {i}-12\,c\,d^2\,f+d^3\,3{}\mathrm {i}\right )\,1{}\mathrm {i}}{512\,a^2\,f^4}+\frac {d^3\,x^3\,1{}\mathrm {i}}{16\,a^2\,f}-\frac {d\,x\,\left (-8\,c^2\,f^2+c\,d\,f\,4{}\mathrm {i}+d^2\right )\,3{}\mathrm {i}}{128\,a^2\,f^3}-\frac {d^2\,x^2\,\left (-4\,c\,f+d\,1{}\mathrm {i}\right )\,3{}\mathrm {i}}{64\,a^2\,f^2}\right )+\frac {c^3\,x}{4\,a^2}+\frac {d^3\,x^4}{16\,a^2}+\frac {3\,c^2\,d\,x^2}{8\,a^2}+\frac {c\,d^2\,x^3}{4\,a^2} \]
[In]
[Out]